package com.dbingtech.iot.mqtt;

/**
 * 响应EMQX的WebHook消息，具体修改：emqx_web_hook.conf，怎么配置：https://docs.emqx.net/broker/latest/cn/advanced/webhook.html
 *
 *
 * ##====================================================================
 * ## WebHook
 * ##====================================================================
 *
 * ## The web services URL for Hook request
 * ##
 * ## Value: String
 * web.hook.api.url = http://127.0.0.1:8080
 *
 * ## Encode message payload field
 * ##
 * ## Value: base64 | base62
 * ## web.hook.encode_payload = base64
 *
 * ##--------------------------------------------------------------------
 * ## Hook Rules
 *
 * ## These configuration items represent a list of events should be forwarded
 * ##
 * ## Format:
 * ##   web.hook.rule.<HookName>.<No> = <Spec>
 * web.hook.rule.client.connect.1       = {"action": "on_client_connect"}
 * web.hook.rule.client.connack.1       = {"action": "on_client_connack"}
 * web.hook.rule.client.connected.1     = {"action": "on_client_connected"}
 * web.hook.rule.client.disconnected.1  = {"action": "on_client_disconnected"}
 * web.hook.rule.client.subscribe.1     = {"action": "on_client_subscribe"}
 * web.hook.rule.client.unsubscribe.1   = {"action": "on_client_unsubscribe"}
 * web.hook.rule.session.subscribed.1   = {"action": "on_session_subscribed"}
 * web.hook.rule.session.unsubscribed.1 = {"action": "on_session_unsubscribed"}
 * web.hook.rule.session.terminated.1   = {"action": "on_session_terminated"}
 * web.hook.rule.message.publish.1      = {"action": "on_message_publish"}
 * web.hook.rule.message.delivered.1    = {"action": "on_message_delivered"}
 * web.hook.rule.message.acked.1        = {"action": "on_message_acked"}
 *
 *
 * Event 触发事件
 * 目前支持以下事件：
 *
 * 名称	说明	执行时机
 * client.connect	处理连接报文	服务端收到客户端的连接报文时
 * client.connack	下发连接应答	服务端准备下发连接应答报文时
 * client.connected	成功接入	客户端认证完成并成功接入系统后
 * client.disconnected	连接断开	客户端连接层在准备关闭时
 * client.subscribe	订阅主题	收到订阅报文后，执行 client.check_acl 鉴权前
 * client.unsubscribe	取消订阅	收到取消订阅报文后
 * session.subscribed	会话订阅主题	完成订阅操作后
 * session.unsubscribed	会话取消订阅	完成取消订阅操作后
 * message.publish	消息发布	服务端在发布（路由）消息前
 * message.delivered	消息投递	消息准备投递到客户端前
 * message.acked	消息回执	服务端在收到客户端发回的消息 ACK 后
 * message.dropped	消息丢弃	发布出的消息被丢弃后
 */
public class EmqXWebhookListener {



    /*
        我们主要关心客户端上线、下线
        client.connected	成功接入	客户端认证完成并成功接入系统后
        client.disconnected	连接断开	客户端连接层在准备关闭时
     */


}
